<?php
namespace app\validate;

use think\Validate;

class Register extends Validate
{
    protected $rule = [
        'username' => 'require',
        'phone'  =>  'require|mobile',
        'password' =>  'require|min:6',
    ];

    protected $message = [
        'username.require'  => '请输入您的游戏名称',
        'phone.require' => '请输入您的手机号码',
        'phone.mobile' => '手机号码格式不正确',
        'password.require' => '请输入您的登录密码',
        'password.min'  => '登录密码最少为6位数'
    ];
}